package com.huangwei.service.impl;

import com.huangwei.dao.UserAddressDao;
import com.huangwei.model.UserAddress;
import com.huangwei.service.UserAddressService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class UserAddressServiceImpl implements UserAddressService {
    @Resource
    UserAddressDao userAddressDao;
    @Override
    public List<UserAddress> getAddressByUser(int userId) {
        try {
            return userAddressDao.queryByUser(userId);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return null;
    }
}
